//
//  HomeListCell.swift
//  ListenFM
//
//  Created by 胡定锋Mac on 2017/8/9.
//  Copyright © 2017年 胡定锋. All rights reserved.
//

import UIKit

class HomeListCell: UICollectionViewCell {

    @IBOutlet weak var titleLabel: UILabel!
    @IBOutlet weak var imageview: UIImageView!
    
    @IBOutlet weak var descLabel: UILabel!
    //MARK:- 定义属性
    var model:newfmSubModel?{
        didSet{
            guard let iconURL = URL(string : (model?.cover)!) else {return}
            imageview.kf.setImage(with: iconURL)
            
            titleLabel.text = model?.title
            
            descLabel.text = model?.speak
        }
    }

    //MARK:- 定义属性
    var lessonModel:newlessonSubModel?{
        didSet{
            guard let iconURL = URL(string : (lessonModel?.cover)!) else {return}
            imageview.kf.setImage(with: iconURL)
            
            titleLabel.text = lessonModel?.title
            
            descLabel.text = lessonModel?.speak
        }
    }
    override func awakeFromNib() {
        super.awakeFromNib()
        // Initialization code
    }

}
